import { Tabs, TabItem, Table, TableHead, TableRow, TableCell, TableBody, View } from '@aws-amplify/ui-react';
import ReactPropsTable from '@/components/propsTable/ReactPropsTable';
import { ResponsiveTable, ResponsiveTableCell } from '@/components/ResponsiveTable';
import { CodeHighlight } from '@/components/CodeHighlight';
import { FACE_LIVENESS_DETECTOR_PROPS, FACE_LIVENESS_DETECTOR_COMPONENTS, FACE_LIVENESS_DETECTOR_CONFIG, FACE_LIVENESS_DETECTOR_ERROR_STATES, LIVENESS_ERROR } from './react-props';
## Full API Reference
### FaceLivenessDetectorProps
Below is the full list of props that can be used with the `FaceLivenessDetector` component.
### FaceLivenessDetectorComponents
Below is the full list of props that can be used with the `FaceLivenessDetectorComponents`. You can also reference the [example here](./liveness/customization#components).
### FaceLivenessDetectorConfig
Below is the full list of props that can be used with the `FaceLivenessDetectorConfig`. For instructions on using your own CDN [check here](./liveness/customization#custom-cdn).
Name
Description
Type
binaryPath?
{/* WARNING: Ensure that this URL matches the value in the liveness component */}
Overrides the WASM binary path, the default is https://cdn.liveness.rekognition.amazonaws.com/face-detection/tensorflow/tfjs-backend-wasm/3.11.0/. When overriding this path ensure that the wasm version matches the version of [@tensorflow/tfjs-backend-wasm](https://www.npmjs.com/package/@tensorflow/tfjs-backend-wasm) installed by npm.
faceModelUrl?
{/* WARNING: Ensure that this URL matches the value in the liveness component */}
Overrides the Blazeface model and weights bin CDN URL. Default value is https://cdn.liveness.rekognition.amazonaws.com/face-detection/tensorflow-models/blazeface/0.0.7/model/model.json
### FaceLivenessDetectorCoreConfig
Below is the full list of props that can be used with the `FaceLivenessDetectorCoreConfig`. This config can only be used with the `` component.
Name
Description
Type
binaryPath?
{/* WARNING: Ensure that this URL matches the value in the liveness component */}
Overrides the WASM binary path, the default is https://cdn.liveness.rekognition.amazonaws.com/face-detection/tensorflow/tfjs-backend-wasm/3.11.0/. When overriding this path ensure that the wasm version matches the version of [@tensorflow/tfjs-backend-wasm](https://www.npmjs.com/package/@tensorflow/tfjs-backend-wasm) installed by npm.
faceModelUrl?
{/* WARNING: Ensure that this URL matches the value in the liveness component */}
Overrides the Blazeface model and weights bin CDN URL. Default value is https://cdn.liveness.rekognition.amazonaws.com/face-detection/tensorflow-models/blazeface/0.0.7/model/model.json
credentialProvider?
An optional callback that provides AWS Credentials.
### LivenessError
Below is the LivenessError type used in the `onError` function that should give you more granularity into the types of errors happening in the component.
### LivenessErrorState
Below is the full list of error states that can be returned from the `onError` prop.
### LivenessDisplayText
The text in FaceLivenessDetector is defined as string resources in the component's [displayText.ts file](https://github.com/aws-amplify/amplify-ui/blob/main/packages/react-liveness/src/components/FaceLivenessDetector/displayText.ts).